import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import LoginView from "@/views/登录/LoginView.vue";

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'login',
    component: LoginView
  },
  {
    path: '/wangji',
    name: 'Wangji',
    component:()=> import('@/views/登录/Wangji2View.vue')
  },
  {
    path: '/zhuce',
    name: 'Zhuce',
    component:()=> import('@/views/登录/ZhuceView.vue')
  },
  {
    path: '/home',
    name: 'home',
    component: HomeView,
    children:[
      {
        path: '/leixing',
        name: 'Leixing',
        component:()=> import('@/views/设备管理/SblxView.vue')
      },
      {
        path: '/guanli',
        name: 'Guanli',
        component:()=> import('@/views/设备管理/SbglView.vue')
      },
      {
        path: '/showye',
        name: 'showye',
        component:()=> import('@/views/系统首页/ShowYeView.vue')
      },
      {
        path: '/jkgl',
        name: 'Jkgl',
        component:()=> import('@/views/服务管理/FwglView.vue')
      },
      {
        path: '/jkgl1',
        name: 'Jkgl1',
        component:()=> import('@/views/服务管理/Xq1View.vue')
      },
      {
        path: '/jkgl2',
        name: 'Jkgl2',
        component:()=> import('@/views/服务管理/TianView.vue')
      },
      {
        path: '/jkgl3',
        name: 'Jkgl3',
        component:()=> import('@/views/服务管理/JkView.vue')
      },
      {
        path: '/DepartmentView',
        name: 'DepartmentView',
        component:()=> import('@/views/系统管理/DepartmentView.vue')
      },
      {
        path: '/RoleView',
        name: 'RoleView',
        component:()=> import('@/views/系统管理/RoleView.vue')
      },
      {
        path: '/SystemView',
        name: 'SystemView',
        component:()=> import('@/views/系统管理/SystemView.vue')
      },
      {
        path: '/LogView',
        name: 'LogView',
        component:()=> import('@/views/系统管理/LogView.vue')
      },
      {
        path: '/log2View',
        name: 'Log2View',
        component:()=> import('@/views/登录/Log2View.vue')
      },
      {
        path: '/update',
        name: 'Update',
        component:()=> import('@/views/登录/UpdateView.vue')
      },
      {
        path: '/ziliao',
        name: 'Ziliao',
        component:()=> import('@/views/登录/Ziliao.vue')
      },

      {
        path: '/yddgl',
        name: 'yddgl',
        component:()=> import('@/views/移动端管理/yddglView.vue')
      },
      {
        path: '/yddqx',
        name: 'yddqx',
        component:()=> import('@/views/移动端管理/yddqxView.vue')
      },
      {
        path: '/message',
        name: 'message',
        component:()=> import('@/views/移动端管理/messageView.vue')
      },
      {
        path: '/yjqj',
        name: 'yjqj',
        component:()=> import('@/views/监控管理/YjqjView.vue')
      },
      {
        path: '/yjjk',
        name: 'yjjk',
        component:()=> import('@/views/监控管理/YjjkView.vue')
      },
      {
        path: '/jkdw',
        name: 'jkdw',
        component:()=> import('@/views/监控管理/JkdwView.vue')
      } ,
      {
        path: '/fdd',
        name: 'fdd',
        component:()=> import('@/views/监控管理/fddaoView.vue')
      },
      {
        path: '/zjgl',
        name: 'zjgl',
        component:()=> import('@/views/监控管理/ZjglView.vue')
      },
      {
        path: '/ceshi',
        name: 'ceshi',
        component:()=> import('@/views/监控管理/zdyView.vue')
      },
    ]
  },
  {
    path: '/about',
    name: 'about',
    // route level code-splitting
    // this generates a separate chunk (about.[hash].js) for this route
    // which is lazy-loaded when the route is visited.
    component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue')
  }
]

const router = new VueRouter({
  routes
})

export default router
